package com.caijb.redisdemo.controller;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author caijb
 * @version 1.0
 * @data 2025/11/11 03:11
 */

@RestController
public class JVMController {

    @RequestMapping("/testClassLoad")
    public String test() {
        ClassLoader classLoader = JVMController.class.getClassLoader();
        ClassLoader parent = classLoader.getParent();
        System.out.println(parent.getName());
        ClassLoader parent1 = parent.getParent();
//        System.out.println(parent1.getName());
        System.out.println(classLoader.getName());
        return "hello world";
    }
}
